Weird behavior in psql with \copy

Поиск
Список
Период
Сортировка
От Bernd Helmle
Тема Weird behavior in psql with \copy
Дата
Msg-id 14A97C90424DEECFDABB2205@[172.26.14.247]
обсуждение исходный текст
Ответы Re: Weird behavior in psql with \copy  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
Folks,

following example shows a weird behavior with the transaction status 
identifier
in psql's prompt and the \copy command:


bernd@[local]:bernd #= SELECT version();                                                             version 


------------------------------------------------------------------------------------------------------------------------------------PostgreSQL
8.2beta3on x86_64-unknown-linux-gnu, compiled by GCC gcc-4.0 
 
(GCC) 4.0.2 20050808 (prerelease) (Ubuntu 4.0.1-4ubuntu9)
(1 row)

bernd@[local]:bernd #= \set
AUTOCOMMIT = 'on'
PROMPT1 = '%n@%m:%/ %#%x%R '

[...]

bernd@[local]:bernd #= \copy foo TO '/home/bernd/tmp/test.dat'
bernd@[local]:bernd #*= COMMIT;
WARNING:  there is no transaction in progress
COMMIT

I do the COMMIT; just to show that i'm really not in a transaction.

I see the same in PostgreSQL 8.1.4, too. It looks like get_prompt() seems 
to fail to set the
correct prompt because PQtransactionStatus() still reports PGASYNC_BUSY, 
but
i'm not that deep into libpq to nail that really down.

--  Thanks
                   Bernd


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Peter Eisentraut
Дата:
Сообщение: Re: Day and month name localization uses wrong locale category
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Day and month name localization uses wrong locale category